<%--
  Created by IntelliJ IDEA.
  User: Lanan
  Date: 2017/12/20 0020
  Time: 9:54
  To change this template use File | Settings | File Templates.
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/commons/global.jsp" %>
<!DOCTYPE html>
<html>
<head>
    <%--<%@ include file="/commons/basejs.jsp" %>--%>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>用户常用联系人信息修改</title>
</head>
<body>
<style>
    table td{
        font:100% arial,helvetica,sans-serif;
        /*text-align: center;*/
        height:20px;
        border:1px solid #e0e0e0;
        padding-left:5px;
        border: 1px solid #e0e0e0;
    }
    .td1{
        width: 80px;
        /*background-color: rgb(242,242,242);*/
    }
</style>

<form id="user_examination_population_insert_form" method="post">
    <table align="center" width="100%" style="margin-top: 20px" cellpadding="4">
        <tr>
            <td class="td" align="right" width="40%"><lable for="userID">用户:</lable></td>
            <td width="60%">
                <div style="position: relative;height:15px;width:170px;top:-1px; display:inline-block;">
                    <input type="text" name="userId" id="insertUserEP" value="" hidden/>
                    <input type="text" id="autocomplete-ajax-insertUserEP" style="position: absolute; z-index: 2; background: transparent;"/>
                    <input type="text" id="autocomplete-ajax-insertUserEP-x" disabled="disabled" style="color: #CCC; position: absolute; background: transparent; z-index: 1;"/>
                </div>
            </td>
        </tr>
        <tr>
            <td class="td" align="right" width="40%"><lable for="name">常用联系人姓名:</lable></td>
            <td width="60%">
                <input name="name"  class="easyui-validatebox" data-options="missingMessage:'请输入常用联系人姓名', required:true" style="width:150px;"/>
            </td>
        </tr>
        <tr>
            <td  class="td" align="right" width="40%"><lable for="phone">常用联系人电话:</lable></td>
            <td  width="60%">
                <input name="phone" class="easyui-numberbox" data-options="required:true,missingMessage:'请输入常用联系人电话',validType:'mobile'" style="width:150px;"/>
            </td>
        </tr>
        <tr>
            <td class="td" align="right" width="40%"><lable for="identity">常用联系人身份证号码:</lable></td>
            <td width="60%">
                <input name="identity" class="easyui-validatebox" data-options="missingMessage:'请输入常用联系人身份证号码',validType:'idCardNo', required:true" style="width:150px;"/>
            </td>
        </tr>
        <tr>
            <td  class="td" align="right" width="40%"><lable for="age">常用联系人年龄:</lable></td>
            <td  width="60%">
                <input id="examination_population_update_age" name="age" class="easyui-numberbox" data-options="required:false,missingMessage:'请输入常用联系人年龄',validType:'maxlength[3]'"  style="width:150px;"/>
            </td>
        </tr>
        <tr>
            <td class="td" align="right" width="40%"><lable for="sex">性别:</lable></td>
            <td width="60%">
                <select class="easyui-combobox" name="sex" data-options="required:true,panelHeight:'auto',editable:false" style="width:160px;">
                    <option value="0">男</option>
                    <option value="1">女</option>
                </select>
            </td>
        </tr>
        <tr>
            <td class="td" align="right" width="40%"><lable for="def">是否设为默认:</lable></td>
            <td width="60%">
                <select class="easyui-combobox" name="def" data-options="required:true,panelHeight:'auto',editable:false" style="width:160px;">
                    <option value="0">否</option>
                    <option value="1">是</option>
                </select>
            </td>
        </tr>
    </table>

    <div style="margin-top: 20px;text-align: center">
        <a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-save'", onclick="insertUserExaminationPopulation()">提交</a>
        <a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-cancel'", onclick="$('#user_examination_population_insert').dialog('close')">取消</a>
    </div>
</form>


<script type="text/javascript">
    $(function () {
        autoCompleteDate('${path}/user/address/autoCompleteData.do', 'autocomplete-ajax-insertUserEP', 'insertUserEP', 'autocomplete-ajax-insertUserEP-x')
    })

    function insertUserExaminationPopulation() {
        var userID = $("#insertUserEP").val();
        if (userID == null || userID == "" || userID.length <= 0) {
            $.messager.alert("提示", "用户信息出错!","info");
            return;
        }
        lananUpdateOrInsert("添加", "${path}/user/examination/population/insert.do", "user_examination_population_insert_form", "user_examination_population_insert", "user_examination_population_datagrid")
    }

</script>

<script type="text/javascript" src="${staticPath }/static/validType.js"></script>

</body>
</html>
